#include <iostream>
using namespace std;

//计算n的阶乘
int main(int argc ,char **argv)
{
    int n,i;
    double result=0;

    cout<<"请输入正整数"<<endl;
    
    cin>>n;

    if(n<1)
    {
        cout<<"输入错误！"<<endl;
        return 1;
    }

    result=1;

    for(i=2;i<=n;i++)
    {
        result*=i;
    }
    cout<<result<<endl;
    return 0;
}
